function addFormItem(f, tlbId, i)
{
  var tlbTable = document.getElementById(tlbId);
  
  if(tlbTable != null)
  {
    var tlbBody = tlbTable.getElementsByTagName('tbody')[0];
    if(tlbBody != null)
        tlbTable = tlbBody.getElementsByTagName('tr')[0];
    else
        tlbTable = tblTable.getElementsByTagName('tr')[0];
    
    
    var btn = document.createElement('td');
    btn.innerHTML = f;
    btn.className = (f == '|') ? 'ms-separator' : 'ms-toolbar';
    
    if(i == null)
        tlbTable.appendChild(btn);
    else
        tlbTable.insertBefore(btn, tlbTable.childNodes[i])
  }
}

function addFormSeparator(tlbId, i)
{
  addFormItem('|', tlbId, i);
}